Optimal. Leaf size=77 \[ \frac{a \cos ^3(e+f x)}{3 f}-\frac{a \cos (e+f x)}{f}-\frac{b \sin ^3(e+f x) \cos (e+f x)}{4 f}-\frac{3 b \sin (e+f x) \cos (e+f x)}{8 f}+\frac{3 b x}{8} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0583029, antiderivative size = 77, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 4, integrand size = 19, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.21, Rules used = {2748, 2633, 2635, 8} \[ \frac{a \cos ^3(e+f x)}{3 f}-\frac{a \cos (e+f x)}{f}-\frac{b \sin ^3(e+f x) \cos (e+f x)}{4 f}-\frac{3 b \sin (e+f x) \cos (e+f x)}{8 f}+\frac{3 b x}{8} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2748
Rule 2633
Rule 2635
Rule 8
Rubi steps
\begin{align*} \int \sin ^3(e+f x) (a+b \sin (e+f x)) \, dx &=a \int \sin ^3(e+f x) \, dx+b \int \sin ^4(e+f x) \, dx\\ &=-\frac{b \cos (e+f x) \sin ^3(e+f x)}{4 f}+\frac{1}{4} (3 b) \int \sin ^2(e+f x) \, dx-\frac{a \operatorname{Subst}\left (\int \left (1-x^2\right ) \, dx,x,\cos (e+f x)\right )}{f}\\ &=-\frac{a \cos (e+f x)}{f}+\frac{a \cos ^3(e+f x)}{3 f}-\frac{3 b \cos (e+f x) \sin (e+f x)}{8 f}-\frac{b \cos (e+f x) \sin ^3(e+f x)}{4 f}+\frac{1}{8} (3 b) \int 1 \, dx\\ &=\frac{3 b x}{8}-\frac{a \cos (e+f x)}{f}+\frac{a \cos ^3(e+f x)}{3 f}-\frac{3 b \cos (e+f x) \sin (e+f x)}{8 f}-\frac{b \cos (e+f x) \sin ^3(e+f x)}{4 f}\\ \end{align*}
Mathematica [A] time = 0.164443, size = 76, normalized size = 0.99 \[ -\frac{3 a \cos (e+f x)}{4 f}+\frac{a \cos (3 (e+f x))}{12 f}+\frac{3 b (e+f x)}{8 f}-\frac{b \sin (2 (e+f x))}{4 f}+\frac{b \sin (4 (e+f x))}{32 f} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.014, size = 60, normalized size = 0.8 \begin{align*}{\frac{1}{f} \left ( b \left ( -{\frac{\cos \left ( fx+e \right ) }{4} \left ( \left ( \sin \left ( fx+e \right ) \right ) ^{3}+{\frac{3\,\sin \left ( fx+e \right ) }{2}} \right ) }+{\frac{3\,fx}{8}}+{\frac{3\,e}{8}} \right ) -{\frac{a \left ( 2+ \left ( \sin \left ( fx+e \right ) \right ) ^{2} \right ) \cos \left ( fx+e \right ) }{3}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.66268, size = 77, normalized size = 1. \begin{align*} \frac{32 \,{\left (\cos \left (f x + e\right )^{3} - 3 \, \cos \left (f x + e\right )\right )} a + 3 \,{\left (12 \, f x + 12 \, e + \sin \left (4 \, f x + 4 \, e\right ) - 8 \, \sin \left (2 \, f x + 2 \, e\right )\right )} b}{96 \, f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.61581, size = 157, normalized size = 2.04 \begin{align*} \frac{8 \, a \cos \left (f x + e\right )^{3} + 9 \, b f x - 24 \, a \cos \left (f x + e\right ) + 3 \,{\left (2 \, b \cos \left (f x + e\right )^{3} - 5 \, b \cos \left (f x + e\right )\right )} \sin \left (f x + e\right )}{24 \, f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 1.74778, size = 144, normalized size = 1.87 \begin{align*} \begin{cases} - \frac{a \sin ^{2}{\left (e + f x \right )} \cos{\left (e + f x \right )}}{f} - \frac{2 a \cos ^{3}{\left (e + f x \right )}}{3 f} + \frac{3 b x \sin ^{4}{\left (e + f x \right )}}{8} + \frac{3 b x \sin ^{2}{\left (e + f x \right )} \cos ^{2}{\left (e + f x \right )}}{4} + \frac{3 b x \cos ^{4}{\left (e + f x \right )}}{8} - \frac{5 b \sin ^{3}{\left (e + f x \right )} \cos{\left (e + f x \right )}}{8 f} - \frac{3 b \sin{\left (e + f x \right )} \cos ^{3}{\left (e + f x \right )}}{8 f} & \text{for}\: f \neq 0 \\x \left (a + b \sin{\left (e \right )}\right ) \sin ^{3}{\left (e \right )} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.68039, size = 89, normalized size = 1.16 \begin{align*} \frac{3}{8} \, b x + \frac{a \cos \left (3 \, f x + 3 \, e\right )}{12 \, f} - \frac{3 \, a \cos \left (f x + e\right )}{4 \, f} + \frac{b \sin \left (4 \, f x + 4 \, e\right )}{32 \, f} - \frac{b \sin \left (2 \, f x + 2 \, e\right )}{4 \, f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]